{extend name="public/base" /}
{block name="title"}管理员列表{/block}
{block name="css"}{/block}
{block name="main"}
<div class="row border-bottom white-bg page-heading">
    <div class="col-lg-9">
        <h2>权限控制</h2>
        <ol class="breadcrumb">
            <li class="active">
                <a href="{:url('Rule/userList')}">管理员列表</a>
            </li>
        </ol>
    </div>
</div>

<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="ibox float-e-margins">
            <div class="ibox-title">
                <h5>管理员列表 </h5>
                <div class="ibox-tools">
                    <a class="collapse-link">
                        <i class="fa fa-chevron-up"></i>
                    </a>
                    <a class="dropdown-toggle" data-toggle="dropdown" href="#">
                        <i class="fa fa-wrench"></i>
                    </a>
                    <ul class="dropdown-menu dropdown-user">
                        <li><a href="{:url('Rule/addAdmin')}">添加管理员</a></li>
                    </ul>
                    <a class="close-link">
                        <i class="fa fa-times"></i>
                    </a>
                </div>
            </div>
            <div class="ibox-content" style="padding:10px">
                <a href="{:url('Rule/addAdmin')}" class="btn btn-success">添加管理员</a>
                <div class="table-responsive">
                    <table class="table table-striped table-bordered table-hover table-condensed">
                        <tr>
                            <th width="10%">用户名</th>
                            <th>用户组</th>
                            <th>操作</th>
                        </tr>
                        {foreach name="data" item="v"}
                        <tr>
                            <td>{$v['nickname']}</td>
                            <td>
                                {notempty name="v.group"}
                                {volist name="v.group" id="vo" empty="未加入分组"}
                                <span class="label label-info">{$vo.title}</span>
                                {/volist}
                                {/notempty}
                            </td>
                            <td>
                                <a href="{:url('Rule/editAdmin',['id'=>$v['id']])}">修改权限或密码</a>
                            </td>
                        </tr>
                        {/foreach}
                    </table>
                    {$pages|raw}
                </div>
            </div>
        </div>
    </div>
</div>

{/block}
{block name="js"}{/block}